package com.senriot.quickup.domain

import me.chanjar.weixin.mp.bean.result.WxMpOAuth2AccessToken
import me.chanjar.weixin.mp.bean.result.WxMpUser
import javax.persistence.*

@Entity
@Table(name = "kx_wx_user_info")
data class WxUserInfo
(
        @Id
        var id: String? = null,

        @Embedded
        var token: WxMpOAuth2AccessToken?=null,
        @Embedded
        @AttributeOverrides(AttributeOverride(name = "openId", column = Column(name = "u_open_id")),
                AttributeOverride(name = "unionId", column = Column(name = "u_union_id")))
        var userInfo: WxMpUser?=null
)
